OBJ_TEST:= test.o disjointset.o consultant.o
OBJ:= main.o disjointset.o consultant.o

.PHONY: problema2 problema2-test clean

all: problema2 problema2-test

problema2-test: $(OBJ_TEST) Makefile
	g++ -o $@ $(OBJ_TEST) -lrt

problema2: $(OBJ) Makefile
	g++ -o $@ $(OBJ)

%.o: %.cpp
	g++ -o $@ -c $^

clean:
	rm -rf $(OBJ) $(OBJ_TEST) problema2 problema2-test
